import request from '@/utils/request'
import { download } from '@/utils/request'

// 新增会员相册
export function addOrder(data) {
  return request({
    url: '/businessCore/faorder',
    method: 'post',
    data
  })
}

// 修改会员相册
export function updateOrder(data) {
  return request({
    url: '/businessCore/faorder',
    method: 'put',
    data
  })
}

// 删除会员相册
export function delOrder(id) {
  return request({
    url: '/businessCore/faorder/' + id,
    method: 'delete'
  })
}

export function exportOrder(params, fileName) {
  const url = '/businessCore/faorder/export'
  download(
    url,
    params,
    fileName + `_${new Date().getTime()}.xlsx`
  )
}